#ifndef UMLCLASSHEADER_H
#define UMLCLASSHEADER_H

#include <QTextDocument>

#include "uml/umltextchilditem.h"
#include "gui/editors/highlighters/umlclassheaderhighlighter.h"

class UmlClassItem;

class UmlClassHeader : public UmlTextChildItem
{
    Q_OBJECT

    friend class UmlClassItem;
public:
    UmlClassHeader(QGraphicsItem *parent = 0);

    void setClassItem(UmlClassItem *classItem);

    void contextMenuEvent(QGraphicsSceneContextMenuEvent *event);

    void openEditor();

protected:
    UmlClassItem *_classItem;

    UmlClassHeaderHighlighter *_highlighter;

protected slots:
    void updateUmlText();

};

#endif // UMLCLASSHEADER_H
